package com.hopes.bizz.hazard.om.vo;

import com.hopes.bizz.basic.common.constant.enums.ParkBasicModDictEnum;
import com.hopes.bizz.basic.common.constant.enums.ParkBasicSysDictEnum;
import com.hopes.bizz.hazard.common.constant.enums.HazardSysDictEnum;
import com.hopes.bizz.hazard.om.entity.HazRtDataEntity;
import com.hopes.boss.admin.api.resolver.DictResolver;
import com.hopes.boss.admin.api.resolver.enums.AdminDictEnum;
import com.hopes.boss.admin.api.resolver.enums.SysDictEnum;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @author daijie
 * @version 1.0
 * @date 2023/11/3 9:44
 * @Description:
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class MonitorDataPageVO extends HazRtDataEntity {
    private static final long serialVersionUID = -6066047372008263273L;

    private String hazardSourceLevel;

    private String hazardName;

    private Long storageId;

    private String factorName;

    private Boolean useStatus;

    public String getOrgIdStr() {
        return DictResolver.getItemLabelByValue(AdminDictEnum.sys_company, this.getOrgId());
    }

    public String getStorageIdStr() {
        return DictResolver.getItemLabelByValue(ParkBasicModDictEnum.storage_info, this.storageId);
    }

    public String getUseStatusStr() {
        return DictResolver.getItemLabelByValue(SysDictEnum.yes_no_type, this.useStatus);
    }

    public String getHazardSourceIdStr() {
        return DictResolver.getItemLabelByValue(ParkBasicModDictEnum.hazard_source, this.getHazardSourceId());
    }

    public String getHazardSourceLevelStr() {
        return DictResolver.getItemLabelByValue(ParkBasicSysDictEnum.haz_hazard_source_level, this.hazardSourceLevel);
    }

    public String getAlarmFlagStr() {
        return DictResolver.getItemLabelByValue(HazardSysDictEnum.park_monitor_running_status, this.getAlarmFlag());
    }
}
